Product
Socket Now Supports uv.lock Files
Socket now supports uv.lock files to ensure consistent, secure dependency resolution for Python projects and enhance supply chain security.
@gasket/plugin-start
Advanced tools
Enables commands essential to building and running Gasket projects.
This is a default plugin in the Gasket CLI and is always available for use.
Executes the build
lifecycle. Use this to prepare your app for running, such
as bundling files, minifying code, processing assets, etc.
Executes the preboot
and start
lifecycles. Upon building your app, use this
command to run it.
Executes the build
, preboot
and start
lifecycles. This command defaults
the environment to local
, and is intended for local app development, only.
Plugins can hook the start
lifecycle, inspect the command id, and adjust
startup behavior based on if the start or local commands was used. This
is useful, for example, to enabling hot reload or disabling service worker
caching during development.
This simple example hooks the start lifecycle to start up a web server, and changes the port if using the local command.
// gasket-plugin-example.js
const http = require('http');
module.exports = {
name: 'example-server',
hooks: {
async start(gasket) {
// set things unique for the local command
const isLocal = gasket.command.id === 'local';
const port = isLocal ? 3000 : 8000;
const message = isLocal ? 'Hello.' : 'Hello World!';
http.createServer(function (req, res) {
res.write(message);
res.end();
}).listen(port);
}
}
}
Plugins should hook this lifecycle to prepare files for the app to be run.
This lifecycle can be used to run an app, such as by starting up a port listener. Generally, the start lifecycle should only be hooked by one plugin in an app.
This lifecycle can be hooked by plugins to prepare an app before startup. This should be used for in-memory setup, with an on disk prep handled during the build lifecycle.
FAQs
Adds commands for building and starting Gasket apps
The npm package @gasket/plugin-start receives a total of 148 weekly downloads. As such, @gasket/plugin-start popularity was classified as not popular.
We found that @gasket/plugin-start demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 8 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Socket now supports uv.lock files to ensure consistent, secure dependency resolution for Python projects and enhance supply chain security.
Research
Security News
Socket researchers have discovered multiple malicious npm packages targeting Solana private keys, abusing Gmail to exfiltrate the data and drain Solana wallets.
Security News
PEP 770 proposes adding SBOM support to Python packages to improve transparency and catch hidden non-Python dependencies that security tools often miss.